package com.java2104.controller;

import com.java2104.entity.Account;
import com.java2104.service.AccountService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

@Controller
@RequestMapping("/account")
public class AccountController {
    @Autowired
    private AccountService accountService;

    @RequestMapping("/searchBalance")
    @ResponseBody
    public Account searchBalance(String no) {
        return accountService.findAccById(no);
    }
}
